class MailingsWorker < Workling::Base
  def send_mailing(options)
    @user = User.find(options[:user_id])
    @issue = Issue.find(options[:issue_id])
    if options[:way] == "sent"
      OrderMailer.deliver_sent(@user, @issue, options[:url])
    elsif options[:way] == "reopen"
      OrderMailer.deliver_reopen(@user, @issue, options[:url])
    elsif optinos[:way] == "req"
      @req = Requirement.find(options[:req_id])
      OrderMailer.deliver_req(@user, @req, options[:url])
    end
  end
end